package com.hqyj.controller;

import com.hqyj.pojo.DailyRecord;
import com.hqyj.service.service.Yan_getrecordService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import java.util.HashMap;
import java.util.List;

@Controller
@RequestMapping("/record")
public class yanDailyRecoredController {
    @Autowired(required = false)
    Yan_getrecordService yan_getrecordService;


    @ResponseBody
    @RequestMapping("/getRecord")
    public HashMap<String,Object> getRecord(){
        HashMap<String,Object> map = new HashMap<>();
        List<DailyRecord> list = yan_getrecordService.getRecord();
        map.put("code",0);
        map.put("msg","");
        map.put("count",100);
        map.put("data",list);
        return map;
    }
}
